﻿using System;

namespace E.Model
{
    /// <summary>
    /// 实体类UserModel 。(属性说明自动提取数据库字段的描述信息)
    /// </summary>
    [Serializable]
    public class UserModel
    {
        public UserModel()
        { }

        #region Model

        private int _id;
        private string _loginid;
        private string _pwd;
        private string _email;
        private string _username;
        private string _idcard;
        private bool _gender;
        private int _areaid;
        private int _department;
        private DateTime _lastlogintime;
        private string _lastloginip;
        private DateTime _registertime;
        private bool _delflag;
        private DateTime _deltime;

        /// <summary>
        /// 
        /// </summary>
        public int ID
        {
            set { _id = value; }
            get { return _id; }
        }

        /// <summary>
        /// 登录ID
        /// </summary>
        public string LoginID
        {
            set { _loginid = value; }
            get { return _loginid; }
        }

        /// <summary>
        /// 密码
        /// </summary>
        public string Pwd
        {
            set { _pwd = value; }
            get { return _pwd; }
        }

        /// <summary>
        /// Email
        /// </summary>
        public string Email
        {
            set { _email = value; }
            get { return _email; }
        }

        /// <summary>
        /// 姓名
        /// </summary>
        public string UserName
        {
            set { _username = value; }
            get { return _username; }
        }

        /// <summary>
        /// 身份证
        /// </summary>
        public string IDCard
        {
            set { _idcard = value; }
            get { return _idcard; }
        }

        /// <summary>
        /// 性别
        /// </summary>
        public bool Gender
        {
            set { _gender = value; }
            get { return _gender; }
        }

        /// <summary>
        /// 地区
        /// </summary>
        public int AreaID
        {
            set { _areaid = value; }
            get { return _areaid; }
        }

        public string AreaName
        { get; set; }

        /// <summary>
        /// 部门
        /// </summary>
        public int Department
        {
            set { _department = value; }
            get { return _department; }
        }

        /// <summary>
        /// 最后登录时间
        /// </summary>
        public DateTime LastLoginTime
        {
            set { _lastlogintime = value; }
            get { return _lastlogintime; }
        }

        /// <summary>
        /// 最后登录IP
        /// </summary>
        public string LastLoginIP
        {
            set { _lastloginip = value; }
            get { return _lastloginip; }
        }

        /// <summary>
        /// 注册时间
        /// </summary>
        public DateTime RegisterTime
        {
            set { _registertime = value; }
            get { return _registertime; }
        }

        /// <summary>
        /// 删除标识
        /// </summary>
        public bool DelFlag
        {
            set { _delflag = value; }
            get { return _delflag; }
        }

        /// <summary>
        /// 删除时间
        /// </summary>
        public DateTime DelTime
        {
            set { _deltime = value; }
            get { return _deltime; }
        }

        public int CurrentCertificateID
        {
            get;
            set;
        }

        public int CourseID { get; set; }
        public string CourseArrayId { get; set; }
        public string CurrentCertificateName
        { get; set; }

        public int EducationID { get; set; }

        public string Education
        { get; set; }

        public int ForgetPwdQuestionID { get; set; }
        public string ForgetPwdAnswer { get; set; }

        public string SkillGroup { get; set; }
        public int SkillGroupId { get; set; }
        public string Position { get; set; }
        public string Lan { get; set; }
        public string EntryDate { get; set; }
        public string SeparationDate { get; set; }
        public string TrainingDate { get; set; }
        public string SkillCertificate { get; set; }

        public bool IsPublic { get; set; }
        public int DelFlagInt { get; set; }
        public int IsPublicInt { get; set; }

        public string EntryFromDate { get; set; }
        public string EntryToDate { get; set; }

        #endregion Model

    }

    [Serializable]
    public class ShortUserModel
    {
        private int _id;
        private string _loginid;
        private string _username;
        private int _areaid;

        /// <summary>
        /// 
        /// </summary>
        public int ID
        {
            set { _id = value; }
            get { return _id; }
        }

        /// <summary>
        /// 登录ID
        /// </summary>
        public string LoginID
        {
            set { _loginid = value; }
            get { return _loginid; }
        }

        /// <summary>
        /// 姓名
        /// </summary>
        public string UserName
        {
            set { _username = value; }
            get { return _username; }
        }

        public int AreaID
        {
            set { _areaid = value; }
            get { return _areaid; }
        }

        public bool IsPublic { get; set; }
        public bool DelFlag { get; set; }
    }

    [Serializable]
    public class UserCertificateLogModel
    {
        public int ID
        { get; set; }

        public int CertificateID
        { get; set; }

        public string CertificateName
        { get; set; }

        public DateTime AddDate
        { get; set; }
    }

    [Serializable]
    public class ShortUserScoreModel
    { 
        public int ID
        { get; set; }

        public int ExamCategoryID
        { get; set; }

        public string CourseName
        { get; set; }

        public decimal Score
        { get; set; }

        public DateTime AddDate
        { get; set; }
    }

    [Serializable]
    public class ListModel
    {
        public int TotalCount { get; set; }
        public System.Collections.Generic.IList<UserListModel> UserList { get; set; }
    }

    [Serializable]
    public class UserListModel
    {
        public int ID { get; set; }
        public string UserName { get; set; }
        public bool Gender { get; set; }
        public string Email { get; set; }
        public string LoginID { get; set; }
        public string SignedCertificateName { get; set; }
        public bool DelFlag { get; set; }
    }

    [Serializable]
    public class PluralUserModel
    {
        public string Prefix { get; set; }
        public int StartNo { get; set; }
        public int Quantity { get; set; }
        public string Pwd { get; set; }
        public int AreaID { get; set; }
        public int CurrentCertificateID { get; set; }
        public DateTime RegisterTime { get; set; }
        public string CheckCondition { get; set; }
        public int ForgetPwdQuestionID { get; set; }
        public string ForgetPwdAnswer { get; set; }
        public int EducationID { get; set; }
        public bool IsPublic { get; set; }
        public int EndNo { get; set; }
    }

    [Serializable]
    public class PwdQuestionUserModel
    {
        public int ID { get; set; }
        public int UserID { get; set; }
        public string Title { get; set; }
        public string Answer { get; set; }
    }
}